import request from '@/utils/request'

// 查询汽车采购列表
export function listVehicle(query) {
  return request({
    url: '/trade/vehicle/list',
    method: 'get',
    params: query
  })
}

// 查询汽车采购详细
export function getVehicle(orderId) {
  return request({
    url: '/trade/vehicle/' + orderId,
    method: 'get'
  })
}

// 新增汽车采购
export function addVehicle(data) {
  return request({
    url: '/trade/vehicle',
    method: 'post',
    data: data
  })
}

// 修改汽车采购
export function updateVehicle(data) {
  return request({
    url: '/trade/vehicle',
    method: 'put',
    data: data
  })
}

// 删除汽车采购
export function delVehicle(orderId) {
  return request({
    url: '/trade/vehicle/' + orderId,
    method: 'delete'
  })
}
